package com.guli.order.feign;

import com.guli.common.utils.R;
import com.guli.order.vo.OrderItemVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

/**
 * @Author zzb
 * @Date 2024/5/30 20:44
 * @Version 1.0
 * @description
 */
@FeignClient("coupon-service")
public interface CouponFeignService {

    @GetMapping("coupon/couponhistory/available")
    public R getAvailableCoupons(List<OrderItemVo> orderItemVos);

    @RequestMapping("coupon/coupon/info/{id}")
    public R info(@PathVariable("id") Long id);

    @GetMapping("/coupon/coupon/infos/{ids}")
    public R getCouponsByIds(@PathVariable List<Long> ids);

}
